package anbow.math;

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;

public class NumberOfOne {

	public static void main(String[] args) throws IOException {
		
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));		
		String line = br.readLine();
		
		String[] arr = line.split(" ");
		
		int result = 0;//因为0与任何数字做异或操作，结果等于数字本身
		
		for(int i=0;i<arr.length;i++) {
			result = result ^ Integer.valueOf(arr[i]);
		}
		
		System.out.println(result);
		
	}

}
